Learning Flex Basics (Part 3) : Working with Containers
Table of Contents
- Introduction
- Building the Containers
- Create the Application Object
- Create a Data Array
- Add a TabNavigator Container for Global Navigation
- Add an HBox and Panel Containers for Main Views
- Add a ViewStack, LinkBar, and Panel Containers for Secondary Views
- Add a Form Container
- Add a Tile Layout Container and Populate It Using a Repeater
- Create a Pseudo Bar Chart Using a Repeater and VBoxes
- Complete Code Listing for containers.mxml
- Where to Go from Here
Building the Application
The application is simple. The tutorial focuses on learning how to use navigation and layout containers. You will create a global navigation system for two main views using the TabNavigator container. In one of the main views you use the LinkBar and ViewStack navigator containers to create a local navigation system for two secondary views.
In the views, you use a variety of layout containers: Panel, HBox, VBox, Form, and Tile. You also learn how to use the Repeater class to iterate over a data set, and to create event handlers for the repeated items.
Figure 1. Form View
Figure 2. Tile View
Figure 3. Pseudo Bar Chart